package com.awangyh.jdk8.lambda;

/**
 * Created by admin on 2017/3/21.
 */
public class WorkerOldDemo {

    public static void main(String[] args) {
        Thread t = new Thread(new Worker());
        t.start();
    }
}

class Worker implements Runnable {

    public void run() {
        for ( int i = 0; i < 100; i ++) {
            doWork();
        }
    }

    public void doWork(){
        System.out.println("Working now......");
    }
}